/**
 * author:Administrator
 * date:2016/1/4
 */


'use strict';

var mongoose = require('../conn/mongoose.js');

var modelName = '_test_transCoupon';
var model = new mongoose.Schema({
  tid:{type:Number},            /* transactionid */
  cuid: {type: Number},         /* from couponVendor */
  cvid: {type: Number},         /* to couponUser */
  qty:{type:Number,default:0},  /* transaction中的额度 */
  state: {type: String},        /* 事务状态 initial, pending, applied, done, canceling, canceled */
});

module.exports = mongoose.model(modelName, model);